package me.boot.web.common.template.model;


import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Getter;
import lombok.Setter;

/**
 * @author :  sylar
 * @FileName :
 * @CreateDate :  2017/11/08
 * @Description : 分页请求参数
 * @ReviewedBy :
 * @ReviewedOn :
 * @VersionHistory :
 * @ModifiedBy :
 * @ModifiedDate :
 * @Comments :
 * @CopyRight : COPYRIGHT(c) xxx.com All Rights Reserved
 * *******************************************************************************************
 */
@Getter
@Setter
@ApiModel("分页查询参数")
public class PageParam<Model> extends QueryParam {
    public final int DEFAULT_PAGE_SIZE = 20;
    public final int PAGE_SIZE_LIMIT = 1000;

    /**
     * 查询参数，与实体字段命名保持一致
     */
    @ApiModelProperty(value = "查询参数", notes = "内部属性须与实体字段属性命名保持一致")
    private Model model;

    /**
     * 请求的分页索引（从1开始计数）
     */
    @ApiModelProperty(value = "当前页号,从1开始", example = "1")
    private Integer current;

    /**
     * 分页大小（每页数据条数）
     */
    @ApiModelProperty(value = "每页数据条数", example = "20")
    private Integer size;
}

